package schoolWork.work04.test2;

public class People {

    void printLetter(char c) throws NoLowerLetter{
        if(c<'a'||c>'z'){
            NoLowerLetter noLowerLetter = new NoLowerLetter();
            throw noLowerLetter;
        }
        else{
            System.out.print(c);
        }
    }

    void printDigit(char c) throws NoDigit{
        if(c<'1'||c>'9') {
            NoDigit noDigit = new NoDigit();
            throw noDigit;
        }else{
            System.out.print(c);
        }
    }
}


